<template>
    <div>
        <el-table :data="list" style="width: 100%">
            <el-table-column prop="id" label="id" width="180" />
            <el-table-column prop="shopName" label="shopName" width="180" />
            <el-table-column prop="shopDescription" label="shopDescription" />
            <el-table-column label="操作" >
                <template #default="{row}">
                    <el-button type="primary">查看</el-button>
                    <el-button v-Del="['admin']" type="warning">编辑</el-button>
                    <el-button v-Del="['admin']" type="danger">删除</el-button>
                </template>
            </el-table-column>
        </el-table>

    </div>
</template>


<script setup>
import axios from 'axios';
import { ref } from 'vue';

const list = ref([])

const getData = () => {
    axios.get('/api/list').then(res => {
        list.value = res.data.data.data
    })
}

getData()


</script>